import request from '@/api/socialized-servce/index.js' //引入http.js
const api = request

export default {
	
	// 获取知识分类
	queryByConditionArticleType(params){
		let url = 'socialized-science/article/knowType/queryByCondition'
		return api.request(url,'post',{
			...params
		})
	},
	// 获取文章列表
	queryByConditionArticle(params){
		let url = 'socialized-science/article/queryByCondition'
		return api.request(url,'post',{
			...params
		})
	},
	// 获取文章列表 分页
	queryPageByConditionArticle(params){
		let url = 'socialized-science/article/queryPageByCondition'
		return api.request(url,'post',{
			...params
		})
	},
	// 获取文章详情
	queryByIdArticle(params) {
		let url = 'socialized-science/article/queryById'
		return api.request(url, 'get', params)
	},
	// 文章点赞
	thumpUp(id) {
		let url = `socialized-science/article/thumpUp/${id}`
		return api.request(url, 'put')
	},
	// 文章取消点赞
	thumpUpCancel(id) {
		let url = `socialized-science/article/thumpUpCancel/${id}`
		return api.request(url, 'put')
	},
	// 行情咨讯
	queryById(params) {
		let url = 'socialized-market/marketInformation/queryById'
		return api.request(url,'get',params)
	}
}